import javax.servlet.*;
import java.io.IOException;
import java.io.PipedWriter;
import java.io.PrintWriter;
import java.io.StreamCorruptedException;

/**
 * Created by Administrator on 2017/9/25.
 */
public class ServletG extends GenericServlet {
    @Override
    public void service(ServletRequest servletRequest, ServletResponse servletResponse) throws ServletException, IOException {
        ServletConfig config = this.getServletConfig();
        String value = config.getInitParameter("ga");
        PrintWriter out = servletResponse.getWriter();
        out.write("gggggggggg");
        out.write(value);
        out.write("<br/>");
        ServletContext context = this.getServletContext();
        String  path = context.getRealPath("/");
        out.write(path);
        out.write("测试页面");
    }
}
